const { sequelize, DataTypes } = require('../../utill/getSequelize')

//课程考核方式表
const Class_Assessment_method = sequelize.define('Class_Assessment_method', {
  id: {
    type: DataTypes.INTEGER,
    primaryKey: true,
    autoIncrement: true,
  },



  assess_manner: {//考核方式
    type: DataTypes.STRING,
    // allowNull: false,
  },



  examination_manner: {//考试方式
    type: DataTypes.STRING,
    // allowNull: false,
  },


  examination_time: {//考试时间
    type: DataTypes.STRING,
    // allowNull: false,
  },



  content: {//考试说明
    type: DataTypes.STRING,
    // allowNull: false,
  },

  t_user_and_a_c_s_id: {
    type: DataTypes.INTEGER,
    allowNull: false,
  },



});


//同步模型和数据库表
(async () => {
  try {
    await sequelize.sync({ force: false });
    console.log('All models were synchronized successfully.');
  } catch (error) {
    console.log(error);
  }

})();

//提供出去
module.exports = { Class_Assessment_method };